<?php if (!defined('THINK_PATH')) exit();?><!--<meta http-equiv="refresh" content="240"/>-->
<link href="/Public/Admin/css/same.css"  type="text/css" rel="stylesheet"/>
<script src="/Public/js/jquery-1.11.3.min.js" type="text/javascript"></script>
<script src="/Public/js/layer/layer.js" type="text/javascript"></script>
<script src="/Public/Admin/js/SystemManage.js" type="text/javascript"></script>
<div class="a-main-left-content">
    <div class="a_con_title">
        <h4>图书分类管理</h4>
    </div>
    <div class="a_title_tip">
        <img class="a_record_icon" src="/Public/img/record_01.jpg"/>
        <span class="a_record_news">请认真修改以下分类类别，便于进行图书分类管理。</span>
    </div>
    <div class="box_book_class">
        <div class="book_class_top">
            <form action="<?php echo U('Admin/SystemManage/bookClassManageAdd?id=1');?>"  method="get" class="book_class_top1">
            <div class="title_span">
                <span>图书书架分类</span>
            </div>
                <div class="wyz_input_book_class">
                    书架名称：<input type="text" name="book_case_name" onkeyup="this.value = this.value.toUpperCase();">
                </div>
                <div class="button_book_class">
                    <input type="submit" value="添&nbsp;加">
                </div>
            </form>
            <div class="table_book_class">
                <table class="table_hr">
                    <tr >
                        <th>书架名称</th>
                        <th>录入者名称</th>
                        <th>录入时间</th>
                        <th>书架状态</th>
                        <th>操作</th>
                    </tr>
                    <?php if(is_array($_bookCaseInfo)): $i = 0; $__LIST__ = $_bookCaseInfo;if( count($__LIST__)==0 ) : echo "" ;else: foreach($__LIST__ as $key=>$vo): $mod = ($i % 2 );++$i; if($vo['book_case_status'] == 1): ?><tr>
                                <td><?php echo ($vo['book_case_name']); ?></td>
                                <td><?php echo ($vo['a_name']); ?></td>
                                <td><?php echo (date("Y-m-d H:i:s",$vo['book_case_intime'])); ?></td>
                                <td class="status1"><?php echo ($vo['book_case_status']); ?></td>
                                <td>
                                    <button class="del wyz_dd" data-id-del="<?php echo ($vo['book_case_id']); ?>">禁用</button>
                                </td>
                            </tr>
                            <?php else: ?>
                            <tr>
                                <td><?php echo ($vo['book_case_name']); ?></td>
                                <td><?php echo ($vo['a_name']); ?></td>
                                <td><?php echo (date("Y-m-d H:i:s",$vo['book_case_intime'])); ?></td>
                                <td class="status2"><?php echo ($vo['book_case_status']); ?></td>
                                <td>
                                    <button class="rec wyz_bb" data-id-rec="<?php echo ($vo['book_case_id']); ?>">恢复</button>
                                </td>
                            </tr><?php endif; endforeach; endif; else: echo "" ;endif; ?>
                </table>
                <input type="hidden" value="<?php echo U('Admin/SystemManage/bookCaseDel');?>" id="del-url">
                <input type="hidden" value="<?php echo U('Admin/SystemManage/bookCaseRec');?>" id="del-url-1">
            </div>
        </div>

        <div class="book_class_top">
            <form action="<?php echo U('Admin/SystemManage/bookClassManageAdd?id=3');?>" method="get"  class="book_class_top1">
                <div class="title_span">
                    <span>出版社分类</span>
                </div>
                <div class="wyz_input_book_class">
                    出版社名称：<input type="text" name="book_ISBN_name">
                </div>
                <div class="button_book_class">
                    <input type="submit" value="添&nbsp;加">
                </div>
            </form>
            <div class="table_book_class">
                <table class="table_hr">
                    <tr >
                        <th>出版社名称</th>
                        <th>录入者名称</th>
                        <th>录入时间</th>
                        <th>状态</th>
                        <th>操作</th>
                    </tr>
                    <?php if(is_array($_bookIsbnInfo)): $i = 0; $__LIST__ = $_bookIsbnInfo;if( count($__LIST__)==0 ) : echo "" ;else: foreach($__LIST__ as $key=>$so): $mod = ($i % 2 );++$i; if($so['book_isbn_status'] == 1): ?><tr>
                                <td><?php echo ($so['book_isbn_name']); ?></td>
                                <td><?php echo ($so['a_name']); ?></td>
                                <td><?php echo (date("Y-m-d H:i:s",$so['book_isbn_intime'])); ?></td>
                                <td class="status1"><?php echo ($so['book_isbn_status']); ?></td>
                                <td>
                                    <button class="del1 wyz_dd" data-id-del1="<?php echo ($so['book_isbn_id']); ?>">禁用</button>
                                </td>
                            </tr>
                            <?php else: ?>
                            <tr>
                                <td><?php echo ($so['book_isbn_name']); ?></td>
                                <td><?php echo ($so['a_name']); ?></td>
                                <td><?php echo (date("Y-m-d H:i:s",$so['book_isbn_intime'])); ?></td>
                                <td class="status2"><?php echo ($so['book_ISBN_status']); ?></td>
                                <td>
                                    <button class="rec1 wyz_bb" data-id-rec1="<?php echo ($so['book_isbn_id']); ?>">恢复</button>
                                </td>
                            </tr><?php endif; endforeach; endif; else: echo "" ;endif; ?>
                </table>
                <input type="hidden" value="<?php echo U('Admin/SystemManage/bookIsbnDel');?>" id="del-url-2">
                <input type="hidden" value="<?php echo U('Admin/SystemManage/bookIsbnRec');?>" id="del-url-3">
            </div>
        </div>

        <div class="book_class_top">
            <form action="<?php echo U('Admin/SystemManage/bookClassManageAdd?id=2');?>" method="get" class="book_class_top1">
            <div class="title_span">
                <span>图书类型分类</span>
            </div>
                <div class="wyz_input_book_class">
                    图书类型名称：<input type="text" name="book_type_name">
                </div>
                <div class="button_book_class">
                    <input type="submit" value="添&nbsp;加" onclick="tanchu()">
                </div>
            </form>

            <div class="table_book_class">
                <table class="table_hr">
                    <tr >
                        <th>类型名称</th>
                        <th>录入者名称</th>
                        <th>录入时间</th>
                        <th>借阅时间</th>
                        <th>状态</th>
                        <th>操作</th>
                    </tr>
                    <?php if(is_array($_bookTypeInfo)): $i = 0; $__LIST__ = $_bookTypeInfo;if( count($__LIST__)==0 ) : echo "" ;else: foreach($__LIST__ as $key=>$co): $mod = ($i % 2 );++$i; if($co['book_type_status'] == 1): ?><tr>
                                <td><?php echo ($co['book_type_name']); ?></td>
                                <td><?php echo ($co['a_name']); ?></td>
                                <td><?php echo (date("Y-m-d H:i:s",$co['book_type_intime'])); ?></td>
                                <td><?php echo ($co['borrow_time_days']); ?>天</td>
                                <td class="status1"><?php echo ($co['book_type_status']); ?></td>
                                <td>
                                    <button class="del2 wyz_dd" data-id-del2="<?php echo ($co['book_type_id']); ?>">禁用</button>
                                </td>
                            </tr>
                            <?php else: ?>
                            <tr>
                                <td><?php echo ($co['book_type_name']); ?></td>
                                <td><?php echo ($co['a_name']); ?></td>
                                <td><?php echo (date("Y-m-d H:i:s",$co['book_type_intime'])); ?></td>
                                <td><?php echo ($co['borrow_time_days']); ?>天</td>
                                <td class="status2"><?php echo ($co['book_type_status']); ?></td>
                                <td>
                                    <button class="rec2 wyz_bb" data-id-rec2="<?php echo ($co['book_type_id']); ?>">恢复</button>
                                </td>
                            </tr><?php endif; endforeach; endif; else: echo "" ;endif; ?>
                </table>
                <input type="hidden" value="<?php echo U('Admin/SystemManage/bookTypeDel');?>" id="del-url-4">
                <input type="hidden" value="<?php echo U('Admin/SystemManage/bookTypeRec');?>" id="del-url-5">
            </div>
        </div>
    </div>
</div>
<script type="text/javascript">
    $(".status1").html("使用中");
    $(".status2").html("未使用");
</script>